<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<title>薪资发放</title>
<script type="text/javascript" src="static/easyui/jquery.min.js"></script>
<script type="text/javascript" src="static/easyui/jquery.easyui.min.js"></script>
<script type="text/javascript" src="static/easyui/locale/easyui-lang-zh_CN.js"></script>
<link rel="stylesheet" href="static/easyui/themes/icon.css">
<link rel="stylesheet" href="static/easyui/themes/metro-blue/easyui.css">
</head>
<body>
<link rel="stylesheet" href="static/easyui/themes/salary-emp.css">
<style type="text/css">
	*{
		margin:0px;
		padding:0px;
	}
	.background{
		width: 1120px;
	    height: 570px;
	    margin: 0px auto;
	    margin-top: 10px;
	    background-color: #FFF;
	}
	.es-head{
		width: 1125px;
		height:60px;
		margin:0px auto;
	}
	.notice-head{
		width: 1100px;
	    height: 45px;
	    border-bottom: 1px solid #F3F3F9;
	    color: #19AA9A;
	    font-size: 18px;
	    text-align: center;
	    line-height: 45px;
	    font-weight: 700;
	}
	.notice-head{
		width: 1100px;
	    height: 45px;
	    border-bottom: 1px solid #F3F3F9;
	    color: #19AA9A;
	    font-size: 18px;
	    text-align: center;
	    line-height: 45px;
	    font-weight: 700;
	    margin-left: 48px;
	}
	.head-left{
		width: 666px;
	    height: 27px;
	    float: left;
	    margin-top: 20px;
	    margin-left:45px;
	}
	.head-left .textbox{
		width:150px;
	}
	#mingchen,#mingchen1{
		font-size: 14px;
	}
	#mingchen1{
		margin-left:5px;
	}
	#salary-name,#salary-name1,#salary-name2{
		width: 150px;
	    height: 20px;
	    border-radius: 3px;
	    border: 1px solid #ccc;
	}
	.table{
		width: 1020px;
		margin:0px auto;
		margin-top:20px;
		border: 1px solid #E5E5E5;		
	}
	.datagrid-header .datagrid-cell span{
		color: #19AA9A;
	    font-size: 14px;
	    font-weight: 700;
	}
	.datagrid-header .datagrid-cell,.datagrid-cell, .datagrid-cell-group, .datagrid-header-rownumber, .datagrid-cell-rownumber {
		text-align: center;
	}
	.table .datagrid .panel-body{
	 	width: 1017px;
	}
	.datagrid-header{
		height:39px;
	}
	.datagrid-header-row, .datagrid-row {
   	 	height: 40px;
	}
	.bianji,.xiangqing{
		width: 45px;
    	height: 20px;
		font-size:12px;
		border-radius:4px;
	}
	.bianji,.xiangqing{
		width: 45px;
    	height: 20px;
		font-size:12px;
		border-radius:4px;
	}
	.bianji{
		color:#fff;
		background-color:#18A689;
		border:1px solid #18A689;
	}
	.xiangqing{
		color:#666666;
		border:1px solid #E4E4E4;
		background-color:#fff;
	}
	.box{
		width: 400px;
	    height: 280px;
	    background-color: #fff;
	    margin: 0px auto;
	    margin-top: 100px;
	}
	.text-tianjia{
		margin:0px auto;
		width: 100px;
    	font-size: 20px;
	}
	.form-text{
		font-size: 16px;
    	margin-top: 5px;
	}
	.form-text1{
		font-size: 16px;
	    margin-top: 5px;
	    margin-left: 16px;
	}
	#items-name,#items-names{
		width: 170px;
	    height: 25px;
	    border-radius: 4px;
	    border: 1px solid #ccc;
	    margin-left: 5px;
	}
	#items-type,#items-types{
		width: 172px;
	    height: 26px;
	    border-radius: 4px;
	   	margin-left: 5px;
	}
	#items-remarks,#items-remarkss{
		width: 170px;
	    height: 25px;
	    border-radius: 4px;
	    border: 1px solid #ccc;
	    margin-left: 36px;
	}
	.div{
		width: 260px;
	    height: 30px;
	    margin-left: 45px;
	    margin-top: 30px;
	}
	.queding,.bjqueding{
		border: 1px solid #fff;
	    color: #fff;
	    background-color: #18A689;
	    width: 65px;
	    height: 26px;
	    border-radius: 4px;
	    margin-top: 60px;
	}
	.quxiao{		
		width: 65px;
	    height: 25px;
	    border: 1px solid #18A689;
	    color: #18A689;
	    background-color: #fff;
	    border-radius: 4px;
	    margin-left: 5px;
	}
	#zhezhao{
		width:1366px;
		height:736px;
		position:fixed;
		top:0px;
		background: rgba(0, 0, 0, 0.5);
		text-align:center;
		left:0;
		z-index:10;
		display:none;
	}
	#items-form .textbox{
		width:150px;
	}
	.pay-div{
		width:500px;
		height:30px;
		margin: 0px auto;
		margin-top: 20px;
	}
	.pay-text3{
		margin-left: 12px;
	}
	.pay-text4{
		margin-left: 87px;
	}
	.pay-input1{
		width: 150px;
	    height: 25px;
	    background-color: #fff;
	    border: 1px solid #ccc;
	    margin-right: 44px;
	}
	.pay-input2{
		width: 150px;
	    height: 25px;
	    background-color: #fff;
	    border: 1px solid #ccc;
	}
	.window-shadow{
		position: relative;
    	top: -273px;
		background: #F8F8F8;
	    opacity: 0.4;
	    border: 1px solid #F8F8F8;
		
	}
	.guanbi{
		border: 1px solid #ccc;
	    margin-top: 54px;
	    margin-left: 20px;
	    background-color: #fff;
	    width: 50px;
	    height: 25px;
	    margin-right: 10px;
	    line-height: 25px;
	    text-align: center;
	    cursor: pointer;
	    float: left;
	}
	.win-queding{	    
	    border: 1px solid #ccc;
	    margin-top: 54px;
	    margin-left: 235px;
	    background-color: #fff;
	    width: 50px;
	    height: 25px;
	    margin-right: 10px;
	    line-height: 25px;
	    text-align: center;
	    cursor: pointer;
	    float: left;
	}
	.window{
		margin-top:-54px;
	}
	.window .window-body{
		border-top-width: 1px;
		height: 264px;
	}
</style>
<script type="text/javascript">
		function add(text){
			$("#content-admin").panel({
				href:text
			});
		}	
		function mingxi(account_id,sub_id,pay_id){
			$.ajax({
				url:'mingxidpays',
				type:"post",
				dateType:"json",
				data:{account_id:account_id,sub_id:sub_id,pay_id:pay_id},
				success: function (result) {
					alert("发放成功");
					$("#content-admin").panel('open').panel('refresh','salary-pay');
                }
			})
		}
		function paymingxi(pay){
			add("salary-paymingxi?pay_id="+pay);
		}
		$(function(){
			$("#table_account").datagrid({
				url:'show-pay',
				singleSelect:true,			
				columns:[[{field:'pay_id',hidden:true},
						{field:'sp_thems',title:'主题',width:160},
	               		{field:'account_name',title:'套账名称',width:160},
	               		{field:'sub_static',title:'状态',width:160},
	          			{field:'sp_staff_name',title:'创建人',width:160},
	          			{field:'sp_month',title:'创建日期',width:200,
	          				formatter:function formattime(value,row,index){
	    			    		var date = new Date(value);
	    				        var year = date.getFullYear().toString();
	    				        var month = (date.getMonth() + 1);
	    				        var day = date.getDate().toString();
	    				        var hour = date.getHours().toString();
	    				        var minutes = date.getMinutes().toString();
	    				        var seconds = date.getSeconds().toString();
	    				        if (month < 10) {
	    				            month = "0" + month;
	    				        }
	    				        if (day < 10) {
	    				            day = "0" + day;
	    				        }
	    				        if (hour < 10) {
	    				            hour = "0" + hour;
	    				        }
	    				        if (minutes < 10) {
	    				            minutes = "0" + minutes;
	    				        }
	    				        if (seconds < 10) {
	    				            seconds = "0" + seconds;
	    				        }
	    				        return year + "-" + month + "-" + day + " " + hour + ":" + minutes + ":" + seconds;
	    				}},
	               		{field:'caozuo',title:'操作',width:250,
	    					formatter:function(value,row,index){
	          					if(row['sub_static']=="待审核"){
									return "<input type='button'onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' onclick='songseng("+row['sub_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='送审'/>"
									+"<input type='button' onclick='shanchu("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='删除'/>";
								}else if(row['sub_static']=="审核通过"){
									return "<input type='button' onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' type='button' onclick='mingxi("+row['account_id']+","+row['sub_id']+","+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='发放'/>";
								}else if(row['sub_static']=="已发放"){
									return "<input type='button' onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' type='button' onclick='paymingxi("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='明细'/>";
								}else{									
									return "<input type='button' onclick='shanchu("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='删除'/>";
								}
							}								
					  }
	          ]],
	          pagination:true,
			    pageNumber:1,
			    pageSize:5,
			    pageList:[5,10,15]
			});
		});
		$("#ss-2").click(function(){
			var a=$("#salary-name").combogrid('grid');
			var b=a.datagrid('getSelected');
			if(b=="" || b==null){
				alert("请选择套账");
				return false;
			}else{	
				$("#table_account").datagrid({
					url:'find-thems?account_id='+b.account_id,
					singleSelect:true,			
					columns:[[{field:'pay_id',hidden:true},
						{field:'sp_thems',title:'主题',width:160},
	               		{field:'account_name',title:'套账名称',width:160},
	               		{field:'sub_static',title:'状态',width:160},
	          			{field:'sp_staff_name',title:'创建人',width:160},
	          			{field:'sp_month',title:'创建日期',width:200,
	          				formatter:function formattime(value,row,index){
	    			    		var date = new Date(value);
	    				        var year = date.getFullYear().toString();
	    				        var month = (date.getMonth() + 1);
	    				        var day = date.getDate().toString();
	    				        var hour = date.getHours().toString();
	    				        var minutes = date.getMinutes().toString();
	    				        var seconds = date.getSeconds().toString();
	    				        if (month < 10) {
	    				            month = "0" + month;
	    				        }
	    				        if (day < 10) {
	    				            day = "0" + day;
	    				        }
	    				        if (hour < 10) {
	    				            hour = "0" + hour;
	    				        }
	    				        if (minutes < 10) {
	    				            minutes = "0" + minutes;
	    				        }
	    				        if (seconds < 10) {
	    				            seconds = "0" + seconds;
	    				        }
	    				        return year + "-" + month + "-" + day + " " + hour + ":" + minutes + ":" + seconds;
	    				}},
	               		{field:'caozuo',title:'操作',width:250,
	    					formatter:function(value,row,index){
	          					if(row['sub_static']=="待审核"){
									return "<input type='button'onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' onclick='songseng("+row['sub_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='送审'/>"
									+"<input type='button' onclick='shanchu("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='删除'/>";
								}else if(row['sub_static']=="审核通过"){
									return "<input type='button' onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' type='button' onclick='mingxi("+row['account_id']+","+row['sub_id']+","+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='发放'/>";
								}else if(row['sub_static']=="已发放"){
									return "<input type='button' onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' type='button' onclick='paymingxi("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='明细'/>";
								}else{									
									return "<input type='button' onclick='shanchu("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='删除'/>";
								}
							}						
					  }
		          ]],
		          queryParams: {
		        	account_id:b.account_id
		      		},
		          pagination:true,
				    pageNumber:1,
				    pageSize:5,
				    pageList:[5,10,15]
				});
			}
		});
		$("#ss-2").dblclick(function(){
			$("#table_account").datagrid({
				url:'show-pay',
				singleSelect:true,			
				columns:[[{field:'pay_id',hidden:true},
						{field:'sp_thems',title:'主题',width:160},
	               		{field:'account_name',title:'套账名称',width:160},
	               		{field:'sub_static',title:'状态',width:160},
	          			{field:'sp_staff_name',title:'创建人',width:160},
	          			{field:'sp_month',title:'创建日期',width:200,
	          				formatter:function formattime(value,row,index){
	    			    		var date = new Date(value);
	    				        var year = date.getFullYear().toString();
	    				        var month = (date.getMonth() + 1);
	    				        var day = date.getDate().toString();
	    				        var hour = date.getHours().toString();
	    				        var minutes = date.getMinutes().toString();
	    				        var seconds = date.getSeconds().toString();
	    				        if (month < 10) {
	    				            month = "0" + month;
	    				        }
	    				        if (day < 10) {
	    				            day = "0" + day;
	    				        }
	    				        if (hour < 10) {
	    				            hour = "0" + hour;
	    				        }
	    				        if (minutes < 10) {
	    				            minutes = "0" + minutes;
	    				        }
	    				        if (seconds < 10) {
	    				            seconds = "0" + seconds;
	    				        }
	    				        return year + "-" + month + "-" + day + " " + hour + ":" + minutes + ":" + seconds;
	    				}},
	               		{field:'caozuo',title:'操作',width:250,
	    					formatter:function(value,row,index){
	          					if(row['sub_static']=="待审核"){
									return "<input type='button'onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' onclick='songseng("+row['sub_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='送审'/>"
									+"<input type='button' onclick='shanchu("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='删除'/>";
								}else if(row['sub_static']=="审核通过"){
									return "<input type='button' onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' type='button' onclick='mingxi("+row['account_id']+","+row['sub_id']+","+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='发放'/>";
								}else if(row['sub_static']=="已发放"){
									return "<input type='button' onclick='chakan("+row['account_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='查看'/>"
									+"<input type='button' type='button' onclick='paymingxi("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='明细'/>";
								}else{									
									return "<input type='button' onclick='shanchu("+row['pay_id']+")' style='width: 45px;height: 18px;font-size: 12px;margin-right: 5px;color: #000;background-color: #fff;border: 1px solid #fff;border-right: 1px solid #18A689;' value='删除'/>";
								}
							}								
					  }
	          ]],
	          pagination:true,
			    pageNumber:1,
			    pageSize:5,
			    pageList:[5,10,15]
			});
		});
		function tianjiapay(){
			$("#zhezhao").show();
		}
		function quedingxz(){
			var a=$("#items-type").combogrid('grid');
			var b=a.datagrid('getSelected');
			var accountname=b.account_name;
			$.ajax({
				url:'tianjia-pay',
				type:"post",
				dateType:"json",
				data:{account_name:accountname},
				success: function (result) {
					
                }
			})
		}
		$('#items-type').combogrid({
	        panelWidth:250,
	        url:'select_sousuoKuang',
	        singleSelect:true,
	        idField:'Staff_name',
	        treeField:'Staff_name',
	        columns:[[
	        	{field:'sortable',title:'#',width:28},
	        	{field:'staff_id',hidden:true},
	            {field:'Staff_name',title:'姓名',width:60},
	            {field:'depart_name',title:'部门',width:60},
	            {field:'Staff_phone',title:'联系电话',width:100}
	        ]],
	        onClickRow:function(rowIndex, rowData){
	    		$("#sheng").val(rowData['staff_id']);
	    	}
	    });
		function chakan(pays){
			$('#win').window('open');
			$.ajax({
				url:'pay-ck',
				type:'post',
				datType:'json',
				data:{account_id:pays},
				success:function(result){
					//获取月份
					var date=result[0]["sp_month"]+"";
					$("#thems").val(result[0]["sp_thems"]);
					$("#account").val(result[0]["account_name"]);
					$("#cjr").val(result[0]["sp_staff_name"]);
					$("#shr").val(result[0]["sub_staffname"]);	
					var results="";
					if(result[0]["sub_judge"]=='是'){
						results="通过";
					}else if(result[0]["sub_judge"]=='否'){
						results="不通过";
					}else{
						results="";
					}
					$("#result").val(results);
					
				}
			})
			$.ajax({
				url:'pay-cks',
				type:'post',
				datType:'json',
				data:{account_id:pays},
				success:function(result){
					/* $("#ssry").val(""); */
					var ss="";
					for(var i=0;i<result.length;i++){	
						ss+=result[i]["Staff_name"]+",";
						var dss = ss.substr(0,ss.length-1);						
						$("#ssry").val(dss);	
						
					}
				}
			})
		}
		function shanchu(id){
			$.ajax({
				url:'delect-pay',
				type:'post',
				data:{pay_id:id},
				success:function(result){
					alert("删除成功");
					add("salary-pay");
				}
			})
		}
		function xinzengpay(){
			$("#win_1").form('clear');
			$('#win_1').window('open');
			$('#items-name').combogrid({
		        panelWidth:400,
		        url:'findaccountselect',
		        singleSelect:true,
		        idField:'account_id',
		        treeField:'account_name',
		        columns:[[{field:'account_id',title:'套账编号',width:85},
						{field:'account_name',title:'套账名称',width:85},
		           		{field:'sa_dass',title:'薪资等级',width:60},
		      			{field:'Staff_name',title:'创建人',width:60},
		      			{field:'sa_remarks',title:'备注',width:80}
		        ]]
		    });
		}
		function songseng(sub_id){
			add("salary-shenqing?sub_id="+sub_id)
		}
		function quedingpay(){
			var a=$("#account_1").combogrid('grid');
			var b=a.datagrid('getSelected');
			var them=$("#thems_1").val();
			if(them==""||them==null){
				alert("请输入发放主题");
				return false;
			}else if(b==""||b==null){
				alert("请选择套账");
			}else{
				$('#pay-form').form('submit', {
					url:'xzpay-add',
					onSubmit: function(param){
						var thems=$("#thems_1").val();
						param.account_id = b.account_id;
						param.sp_thems=thems;					
					},
					success:function(data){
						alert("发放新增成功");
						$('#win_1').window('close');
						$("#content-admin").panel('open').panel('refresh','salary-pay');
				    }
				});
			}			
		}
		function guanbi(){
			$('#win_1').window('close');
		}
</script>
<div id="zhezhao">
		<div class="box">
			<div class="text-tianjia">添加发放</div>
			<form id="items-form">
				<div class="div"><span class="form-text">套账名称:</span>
				<input type="text" id="items-name" editable="false" style="width:150px;">
				</div>
				<div class="div"><span class="form-text1">创建人:</span>
					<input id="items-type" type="text">
				</div>
				<button class="queding" onclick="quedingxz()">确定</button><button class="quxiao">取消</button>
			</form>
		</div>
</div>
	<div class="background">
			<div class="notice-head">薪资发放</div>
			<div class="es-head">
				<div class="head-left">
					<span id="mingchen">套账名称：</span>
					<select id="salary-name" editable="false" class="easyui-combogrid" name="salaryaccount" style="width:150px;"
					    data-options="
					    panelWidth:400,
					    idField:'account_id',
					    textField:'account_name',
					    url:'selectthems',
					    columns:[[{field:'sp_thems',title:'主题',width:60},
			               		{field:'account_name',title:'套账名称',width:60},
			               		{field:'sub_static',title:'状态',width:60},
			          			{field:'sp_xzmonth',title:'薪资月份',width:80},
			          			{field:'sp_staff_name',title:'创建人',width:60}
					    ]]">
					    </select>
					<a id="ss-2"  class="easyui-linkbutton" data-options="iconCls:'icon-search',plain:true"></a>				
					<a id="tianjia-button"  onclick="xinzengpay()" class="easyui-linkbutton" data-options="iconCls:'icon-add',plain:true"></a>
				</div>
			</div>
			<div class="table">
				<input type='hidden' id='account_id' >
				<input type="hidden" id="" value="${mon.account_id}">
				<fmt:formatDate type='both' var='kai' value='${times.sp_month}'/>
				<input type="hidden" id="times" value="${i}">
				<table id="table_account" class="easyui-datagrid" style="width:1020px;height:400px"></table>
			</div>
			<div id="win" class="easyui-window" title="查看发放" style="width:600px;height:400px;" 
			    data-options="iconCls:'icon-save',modal:true,closed:true">
			    <form id="pay-form">
			    	<div class="pay-div">
			    		<span class="pay-text1"><span style="color:red">*</span>发放主题</span>
			    		<input type="text" disabled="disabled" class="pay-input1" id="thems">
			    		<span class="pay-text2"><span style="color:red">*</span>薪资套账</span>
			    		<input type="text" disabled="disabled" class="pay-input2" id="account">
			    	</div>
			    	<div class="pay-div">
			    		<span class="pay-text3"><span style="color:red">*</span>创建人</span>
			    		<input type="text" disabled="disabled" class="pay-input1" id="cjr">
			    		<span class="pay-text1"><span style="color:red">*</span>人员</span>
			    		<input type="text" disabled="disabled" class="pay-input1" id="ssry">
			    	</div>
			    </form>
			</div>			
			<div id="win_1" class="easyui-window" title="添加发放" style="width:600px;height:250px;" 
			    data-options="iconCls:'icon-save',modal:true,closed:true">
			    <form id="pay-form">
			    	<div class="pay-div">
			    		<span class="pay-text1">发放主题</span>
			    		<input type="text" class="pay-input1" id="thems_1" name="sp_thems">
			    		<span class="pay-text2">薪资套账</span>
			    		<select id="account_1" editable="false" class="easyui-combogrid" name="account_name" style="width:150px;"
					    data-options="
						    panelWidth:400,
						    idField:'account_id',
						    textField:'account_name',
						    url:'payaccounts',
						    columns:[[{field:'xuhao',title:'编号',width:85},
							{field:'account_name',title:'套账名称',width:85},
		               		{field:'sa_dass',title:'薪资等级',width:60},
		          			{field:'Staff_name',title:'创建人',width:60},
		          			{field:'sa_remarks',title:'备注',width:80},
						    ]]">
				</select>
			    	</div>
			    	<div class="win-queding" onclick="quedingpay()">确定</div><div class="guanbi" onclick="guanbi()">取消</div>
			    </form>
			</div>	
	</div>
</body>
</html>